﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using Microsoft.Xna.Framework.Graphics;

using Zarion_Quest.Base;

namespace Zarion_Quest.EnemyTypes
{
    class SpaceEnemy : BaseEnemy
    {
        /// <summary>
        /// Construtor...
        /// </summary>
        /// <param name="texture">Imagem (Sprite Sheet)</param>
        /// <param name="columns">Quantidade de colunas do Sprite Sheet</param>
        /// <param name="rows">Quantidade de Linhas do Sprite Sheet</param>
        /// <param name="hitPoints">Quantidade de "vida" do inimigo</param>
        public SpaceEnemy(Texture2D texture, int columns, int rows, int hitPoints)
            : base(texture, columns, rows, hitPoints)
        {
        }

        public override void collisionNotifier(Object2D caller)
        {
            if (caller is BaseShot)
            {
                HitPoints -= ((BaseShot)caller).Damage;
                if (HitPoints <= 0)
                    destroy();
            }
        }
    }
}
